<table id="activity" class="table table-striped table-bordered">
  <thead>
    <tr>
      <th>User Activity</th>
      <th>Date</th>
    </tr>
  </thead>
  <tbody>
  <% events.each do |event| %>
    <% next if event[:action].blank? or event[:timestamp].blank? %>
    <tr>
      <td><%= event[:action].html_safe %></td>
      <td><%= time_ago_in_words(Time.zone.at(event[:timestamp].to_i)) %> ago</td>
    </tr>
  <% end %>
  </tbody>
</table>
